﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ExpenseSystem.Model;
using ExpenseSystem.Lor;
using ExpenseSystem.Common;
using ExpenseSystem.DataUpdater;
using ExpenseSystem.Fether;
using ExpenseSystem.Core.DataAddOn;

namespace ExpenseSystem.Core.SiteModules
{
    public class SiteBaseManager : SiteManager
    {
        SiteFetcher fetcher = new SiteFetcher();
        public override bool Delete(SiteModel site, out string message)
        {
            return updater.Remove(site, tran, fetcher, out message);
        }

        public override bool DeleteById(long[] siteIds,  out string message)
        {
            bool result = true;
            result = updater.RemoveById(siteIds, tran, fetcher, out message);
            return result;
        }

        public override bool Save(SiteModel site,  out string message,params IAddable<SiteModel>[] addable)
        {
            return updater.Save(site, tran, fetcher, out message);
        }
    }
}
